package com.spe.common.security.annotation;

import com.spe.common.security.component.SpeResourceServerAutoConfiguration;
import com.spe.common.security.component.SpeSecurityBeanDefinitionRegistrar;
import org.springframework.context.annotation.Import;
import org.springframework.security.config.annotation.method.configuration.EnableGlobalMethodSecurity;
import org.springframework.security.oauth2.config.annotation.web.configuration.EnableResourceServer;

import java.lang.annotation.*;

/**
 * @author limingliang
 * @date 2021/1/12 14:04
 */
@Documented
@Inherited
@Target({ElementType.TYPE})
@Retention(RetentionPolicy.RUNTIME)
@EnableResourceServer
@EnableGlobalMethodSecurity(prePostEnabled = true)
@Import({SpeResourceServerAutoConfiguration.class, SpeSecurityBeanDefinitionRegistrar.class})
public @interface EnableSpeResourceServer {
}
